package com.example.week1.model;

import com.example.mylibrary.okhttp.MyCallBack;
import com.example.week1.utils.OkHttpUtils;

import java.util.HashMap;

public class LoginModelImpl implements LoginModel{
    String url="https://www.wanandroid.com/user/login";
    @Override
    public void login(String username, String pwd, MyCallBack myCallBack) {
        HashMap<String, String> hashMap = new HashMap<>();
        hashMap.put("username",username);
        hashMap.put("password",pwd);
        OkHttpUtils.getInstance().post(url,hashMap, myCallBack);
    }
}
